const plugins = [
  "@babel/plugin-transform-runtime",
  "@babel/plugin-transform-modules-commonjs",
  ["@babel/plugin-proposal-class-properties", { loose: false }]
];

if (["production", "prod"].includes(process.env.NODE_ENV)) {
  plugins.push("transform-remove-console");
}

module.exports = {
  presets: [
    [
      "@vue/app",
      {
        modules: false,
        useBuiltIns: "entry"
      }
    ]
  ],
  plugins: plugins
};
